/**
 * 出库申请api
 */
import request from '@/utils/request'

const BASE = '/wms/store-out-apply-detail'

/**
 * 保存出库明细
 * @param {number} id
 * @returens
 */
export function saveDetail(data) {
  return request({
    url: BASE + `/saveDetail`,
    method: 'POST',
    data
  })
}

/**
 * 删除出库明细
 * @param {number} id
 * @returens
 */
export function deleteById(id) {
  return request({
    url: BASE + `/delete/${id}`,
    method: 'GET'
  })
}

/**
 * 获取出库数量
 * @param {number} id
 * @returens
 */
export function getOutTotal(id) {
  return request({
    url: BASE + `/outStoreTotalNum?detailId=${id}`,
    method: 'POST'
  })
}
